import App from './App'
import * as Pinia from 'pinia'
import { createSSRApp } from 'vue'

// #ifdef H5
import lazyPlugin from 'vue3-lazy'
// #enfif
export function createApp() {
  const app = createSSRApp(App)
  // #ifdef H5
  app.use(lazyPlugin, {
    loading: './static/images/common/placeholder.png'
  })
  app.use(Pinia.createPinia())
  // #enfif
  return {
    app,
    Pinia
  }
}
